{% extends "zinnia/base.html" %}
{% load i18n zinnia_tags comments %}

{% block title %}{% trans "Comment preview" %}{% endblock %}

{% block content %}
  {% if form.errors %}
  <h2>
    {% blocktrans count form.errors|length as errors %}Please correct following error.{% plural %}Please correct following errors.{% endblocktrans %}
  </h2>
  {% else %}
  <h2>{% trans "Preview of the comment" %}</h2>
  <ol id="commentList">
    <li id="comment_preview" class="comment {% cycle box1,box2 %} span-15 last">
      <div class="span-2">
	<img src="{% get_gravatar form.cleaned_data.email 60 "G" %}" class="gravatar" alt="form.cleaned_data.name" />
      </div>
      <div class="comment_body span-13 last">
	<div class="span-13 last">
	  {% if form.cleaned_data.url %}
	  <a href="{{ form.cleaned_data.url }}">{{ form.cleaned_data.name }}</a>
	  {% else %}
	  {{ form.cleaned_data.name }}
	  {% endif %}
	  {% trans "on" %} {% now "SHORT_DATETIME_FORMAT" %}
	</div>
	<div class="span-13 last">
	  <cite>
	    {{ comment }}
	  </cite>
	</div>
      </div>
    </li>
  </ol>
  {% endif %}
  <hr />
  {% include "comments/zinnia/entry/form.html" %}
{% endblock %}
